package com.cdtye.itps.cms.service.tunnel;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.cdtye.common.mybatiscore.base.BaseService;
import com.cdtye.itps.cms.dao.tunnel.entity.JcTunnel;
import com.cdtye.itps.cms.dao.tunnel.vo.JcTunnelVo;
import com.cdtye.itps.cms.mapper.tunnel.JcTunnelMapper;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class JcTunnelService extends BaseService<JcTunnelMapper, JcTunnel> {
    /**
     * 根据id获取隧道信息
     * @param tunnelId
     * @return
     */
    public List<Map<String,Object>> getTunnelById(String tunnelId){
        return baseMapper.getTunnelById(tunnelId);
    }

    /**
     * 根据隧道idList获取隧道信息
     * @param vo
     * @return
     */
    public List<Map<String,Object>> getByTunnelIdList(JcTunnelVo vo){
        return baseMapper.getByTunnelIdList(vo);
    }

    /**
     * 隧道列表
     * @param vo
     * @return
     */
    public List<Map<String, Object>> getList(JcTunnelVo vo){
        return baseMapper.getList(vo);
    }

    public IPage<Map<String, Object>> pageList4Brain(JcTunnelVo vo) {
        return baseMapper.pageList4Brain(vo.page(),vo);
    }
}
